from django.db import models


# Create your models here.

class Goods(models.Model):
    title = models.CharField('商品名', max_length=64)
    price = models.DecimalField('价格', max_digits=9, decimal_places=2)
    show_num = models.IntegerField('浏览量', default=0)
    desc = models.TextField('商品描述', default='商品描述')

    class Meta:
        db_table = 'tb_goods'

    def __str__(self):
        return self.title
